<!DOCTYPE html>
<html>
<head>
  <title>AtomicQuery.java</title>
  <meta http-equiv='Content-Type' content='text/html; charset=UTF-8'/>
  <link rel='stylesheet' type='text/css' href='../../../../../coverage.css'/>
  <link rel='shortcut icon' type='image/png' href='../../../../../logo.png'/>
  <script type='text/javascript' src='../../../../../coverage.js'></script>
  <script type='text/javascript' src='../../../../../prettify.js'></script>
</head>
<body onload='prettyPrint()'>
  <table cellpadding='0' cellspacing='1'>
    <caption>igraph_client_java/src/main/java/com/taobao/igraph/client/model/AtomicQuery.java</caption>
    <tr>
      <td class='line'>1</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>package com.taobao.igraph.client.core.model;</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td><pre class='imports prettyprint' onclick='showHideLines(this)'><div>import com.taobao.igraph.client.common.IGraphClientException;
import com.taobao.igraph.client.common.URLCodecUtil;
import lombok.NonNull;

import java.util.ArrayList;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
</div><span>import ...</span></pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>13</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>public class AtomicQuery extends PGQuery {</pre></td>
    </tr>
    <tr>
      <td class='line'>14</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private Map&lt;String, String> kvPairs;</pre></td>
    </tr>
    <tr>
      <td class='line'>15</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private Map&lt;String, String> alias;</pre></td>
    </tr>
    <tr>
      <td class='line'>16</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String table;</pre></td>
    </tr>
    <tr>
      <td class='line'>17</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String keys;</pre></td>
    </tr>
    <tr>
      <td class='line'>18</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String filter;</pre></td>
    </tr>
    <tr>
      <td class='line'>19</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String orderby;</pre></td>
    </tr>
    <tr>
      <td class='line'>20</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String distinct;</pre></td>
    </tr>
    <tr>
      <td class='line'>21</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String sorter;</pre></td>
    </tr>
    <tr>
      <td class='line'>22</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private String[] fields;</pre></td>
    </tr>
    <tr>
      <td class='line'>23</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private int start;</pre></td>
    </tr>
    <tr>
      <td class='line'>24</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private int count;</pre></td>
    </tr>
    <tr>
      <td class='line'>25</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private boolean isRangeValid;</pre></td>
    </tr>
    <tr>
      <td class='line'>26</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private boolean isJoinQueryOnly;</pre></td>
    </tr>
    <tr>
      <td class='line'>27</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    private List&lt;KeyList> keyLists;</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     * 仅仅在join query里才使用这个构造函数
     *
     * @param table
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>34</td><td class='count'>1</td>
      <td><pre class='prettyprint jmp'>    <span id='l34s0' title='Executions: 1' class='covered'>public AtomicQuery(@NonNull String table) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>35</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l35s0'>        this.table = table;</pre></td>
    </tr>
    <tr>
      <td class='line'>36</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l36s0'>        this.kvPairs = new LinkedHashMap&lt;String, String>();</pre></td>
    </tr>
    <tr>
      <td class='line'>37</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l37s0'>        this.alias = new LinkedHashMap&lt;String, String>();</pre></td>
    </tr>
    <tr>
      <td class='line'>38</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l38s0'>        this.isRangeValid = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>39</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l39s0'>        this.isJoinQueryOnly = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>40</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l40s0'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>42</td><td class='count'>1</td>
      <td><pre class='prettyprint jmp'>    <span id='l42s0' title='Executions: 1' class='covered'>public AtomicQuery(@NonNull String table, @NonNull KeyList keyList) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>43</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l43s0'>        this(table);</pre></td>
    </tr>
    <tr>
      <td class='line'>44</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l44s0'>        this.isJoinQueryOnly = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>45</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l45s0'>        this.keys = keyList.toString();</pre></td>
    </tr>
    <tr>
      <td class='line'>46</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l46s0'>        this.keyLists = new ArrayList&lt;KeyList>();</pre></td>
    </tr>
    <tr>
      <td class='line'>47</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l47s0'>        keyLists.add(keyList);</pre></td>
    </tr>
    <tr>
      <td class='line'>48</td><td class='count'>1</td>
      <td><pre class='prettyprint covered' id='l48s0'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>50</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l50s0' title='Executions: 0' class='uncovered'>public AtomicQuery(@NonNull String table, @NonNull List&lt;KeyList> keyLists) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>51</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l51s0'>        this(table);</pre></td>
    </tr>
    <tr>
      <td class='line'>52</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l52s0'>        this.isJoinQueryOnly = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>53</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l53s0' title='Executions: 0' class='uncovered'>if (keyLists.isEmpty())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>54</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l54s0'>            throw new IGraphClientException("Empty keyLists is not allowed!");</pre></td>
    </tr>
    <tr>
      <td class='line'>55</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>56</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l56s0'>        StringBuilder ss = new StringBuilder();</pre></td>
    </tr>
    <tr>
      <td class='line'>57</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l57s0'>        boolean first = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>58</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l58s0' title='Executions: 0' class='uncovered'>for (KeyList keyList</span> : <span id='l58s1' title='Executions: 0' class='uncovered'>keyLists)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>59</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l59s0' title='Executions: 0' class='uncovered'>if (!first)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>60</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l60s0'>                ss.append(";");</pre></td>
    </tr>
    <tr>
      <td class='line'>61</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>62</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l62s0'>            first = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>63</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l63s0'>            ss.append(keyList.toString());</pre></td>
    </tr>
    <tr>
      <td class='line'>64</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>65</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l65s0'>        this.keys = ss.toString();</pre></td>
    </tr>
    <tr>
      <td class='line'>66</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l66s0'>        this.keyLists = keyLists;</pre></td>
    </tr>
    <tr>
      <td class='line'>67</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l67s0'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>69</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l69s0' title='Executions: 0' class='uncovered'>public AtomicQuery setReturnFields(@NonNull String... fields) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>70</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l70s0' title='Executions: 0' class='uncovered'>if (fields.length == 0)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>71</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l71s0'>            throw new IGraphClientException("empty returnFields is not allowed!");</pre></td>
    </tr>
    <tr>
      <td class='line'>72</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>73</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l73s0'>        this.fields = fields;</pre></td>
    </tr>
    <tr>
      <td class='line'>74</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l74s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>75</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     * 
     * @param start
     * @param count
     * @return
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>83</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    public AtomicQuery setRange(int start, int count) {</pre></td>
    </tr>
    <tr>
      <td class='line'>84</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l84s0' title='Executions: 0' class='uncovered'>if (start &lt; 0</span> || <span id='l84s1' title='Executions: 0' class='uncovered'>count &lt; 0)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>85</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l85s0'>            throw new IGraphClientException("negative start or count is not allowed!");</pre></td>
    </tr>
    <tr>
      <td class='line'>86</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>87</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l87s0'>        this.start = start;</pre></td>
    </tr>
    <tr>
      <td class='line'>88</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l88s0'>        this.count = count;</pre></td>
    </tr>
    <tr>
      <td class='line'>89</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l89s0'>        this.isRangeValid = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>90</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l90s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>91</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     * @param filter
     *            指定过滤条件，过滤条件支持代数表达式，比如： a + b > 10
     * @return
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>98</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l98s0' title='Executions: 0' class='uncovered'>public AtomicQuery setFilter(@NonNull String filter) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>99</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l99s0'>        this.filter = filter;</pre></td>
    </tr>
    <tr>
      <td class='line'>100</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l100s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>101</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /***
     * 
     * @param orderby
     *            指定采用内置默认排序模块，以及排序维度。比如： +a, -(b * c)
     * 
     * @return
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>110</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l110s0' title='Executions: 0' class='uncovered'>public AtomicQuery setOrderby(@NonNull String orderby) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>111</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l111s0'>        this.orderby = orderby;</pre></td>
    </tr>
    <tr>
      <td class='line'>112</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l112s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>113</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     *
     * @param sorter
     *            指定采用用户定制的排序模块进行排序 注：sorter和orderby参数如果同时使用，只有sorter生效。
     * @return
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>121</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l121s0' title='Executions: 0' class='uncovered'>public AtomicQuery setSorter(@NonNull String sorter) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>122</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l122s0'>        this.sorter = sorter;</pre></td>
    </tr>
    <tr>
      <td class='line'>123</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l123s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>124</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     *
     * @param distinct
     *            指定采用用户定制的排序模块进行排序 注：sorter和orderby参数如果同时使用，只有sorter生效。
     * @return
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>133</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l133s0' title='Executions: 0' class='uncovered'>public AtomicQuery setDistinct(@NonNull String distinct) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>134</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l134s0'>        this.distinct = distinct;</pre></td>
    </tr>
    <tr>
      <td class='line'>135</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l135s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>136</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'></td><td>&nbsp;</td>
      <td class='comment' onclick='showHideLines(this)'><div>    /**
     * @Deprecated use addKvPair instead
     */</div><span>    /*...*/</span></td>
    </tr>
    <tr>
      <td class='line'>141</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    @Deprecated</pre></td>
    </tr>
    <tr>
      <td class='line'>142</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l142s0' title='Executions: 0' class='uncovered'>public AtomicQuery addKvpair(@NonNull String key, @NonNull String value) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>143</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l143s0'>        return addKvPair(key, value);</pre></td>
    </tr>
    <tr>
      <td class='line'>144</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>146</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l146s0' title='Executions: 0' class='uncovered'>public AtomicQuery addKvPair(@NonNull String key, @NonNull String value) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>147</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l147s0'>        kvPairs.put(key, value);</pre></td>
    </tr>
    <tr>
      <td class='line'>148</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l148s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>149</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>151</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l151s0' title='Executions: 0' class='uncovered'>public AtomicQuery setKvPairs(@NonNull Map&lt;String, String> kvPairs) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>152</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l152s0'>        this.kvPairs = kvPairs;</pre></td>
    </tr>
    <tr>
      <td class='line'>153</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l153s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>154</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>156</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l156s0' title='Executions: 0' class='uncovered'>public AtomicQuery addAlia(@NonNull String key, @NonNull String value) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>157</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l157s0'>        alias.put(key, value);</pre></td>
    </tr>
    <tr>
      <td class='line'>158</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l158s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>159</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>161</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>    <span id='l161s0' title='Executions: 0' class='uncovered'>public AtomicQuery setAlias(@NonNull Map&lt;String, String> alias) {</span></pre></td>
    </tr>
    <tr>
      <td class='line'>162</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l162s0'>        this.alias = alias;</pre></td>
    </tr>
    <tr>
      <td class='line'>163</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l163s0'>        return this;</pre></td>
    </tr>
    <tr>
      <td class='line'>164</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>166</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    public String toString() {</pre></td>
    </tr>
    <tr>
      <td class='line'>167</td><td class='count'>2</td>
      <td><pre class='prettyprint covered' id='l167s0'>        StringBuilder ss = new StringBuilder(128);</pre></td>
    </tr>
    <tr>
      <td class='line'>168</td><td class='count'>2</td>
      <td><pre class='prettyprint covered' id='l168s0'>        ss.append("search{table=").append(table);</pre></td>
    </tr>
    <tr>
      <td class='line'>169</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l169s0' title='Executions: 2' class='covered'>if (keys != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>170</td><td class='count'>2</td>
      <td><pre class='prettyprint covered' id='l170s0'>            ss.append("&keys=").append(keys);</pre></td>
    </tr>
    <tr>
      <td class='line'>171</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>172</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l172s0' title='Executions: 2' class='covered'>if (filter != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>173</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l173s0'>            ss.append("&filter=").append(filter);</pre></td>
    </tr>
    <tr>
      <td class='line'>174</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>175</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l175s0' title='Executions: 2' class='covered'>if (orderby != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>176</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l176s0'>            ss.append("&orderby=").append(orderby);</pre></td>
    </tr>
    <tr>
      <td class='line'>177</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>178</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l178s0' title='Executions: 2' class='covered'>if (sorter != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>179</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l179s0'>            ss.append("&sorter=").append(sorter);</pre></td>
    </tr>
    <tr>
      <td class='line'>180</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>181</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l181s0' title='Executions: 2' class='covered'>if (distinct != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>182</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l182s0'>            ss.append("&distinct=").append(distinct);</pre></td>
    </tr>
    <tr>
      <td class='line'>183</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>184</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l184s0' title='Executions: 2' class='covered'>if (!kvPairs.isEmpty())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>185</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l185s0'>            ss.append("&kvpairs=");</pre></td>
    </tr>
    <tr>
      <td class='line'>186</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l186s0'>            boolean first = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>187</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l187s0' title='Executions: 0' class='uncovered'>for (Entry&lt;String, String> entry</span> : <span id='l187s1' title='Executions: 0' class='uncovered'>kvPairs.entrySet())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>188</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>                <span id='l188s0' title='Executions: 0' class='uncovered'>if (!first)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>189</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l189s0'>                    ss.append(";");</pre></td>
    </tr>
    <tr>
      <td class='line'>190</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>                }</pre></td>
    </tr>
    <tr>
      <td class='line'>191</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l191s0'>                first = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>192</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l192s0'>                ss.append(entry.getKey());</pre></td>
    </tr>
    <tr>
      <td class='line'>193</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l193s0'>                ss.append(":");</pre></td>
    </tr>
    <tr>
      <td class='line'>194</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l194s0'>                ss.append(entry.getValue());</pre></td>
    </tr>
    <tr>
      <td class='line'>195</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>196</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>198</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l198s0' title='Executions: 2' class='covered'>if (!alias.isEmpty())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>199</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l199s0'>            ss.append("&alias=");</pre></td>
    </tr>
    <tr>
      <td class='line'>200</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l200s0'>            boolean first = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>201</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l201s0' title='Executions: 0' class='uncovered'>for (Entry&lt;String, String> entry</span> : <span id='l201s1' title='Executions: 0' class='uncovered'>alias.entrySet())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>202</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>                <span id='l202s0' title='Executions: 0' class='uncovered'>if (!first)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>203</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l203s0'>                    ss.append(";");</pre></td>
    </tr>
    <tr>
      <td class='line'>204</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>                }</pre></td>
    </tr>
    <tr>
      <td class='line'>205</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l205s0'>                first = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>206</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l206s0'>                ss.append(entry.getKey());</pre></td>
    </tr>
    <tr>
      <td class='line'>207</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l207s0'>                ss.append(":");</pre></td>
    </tr>
    <tr>
      <td class='line'>208</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l208s0'>                ss.append(entry.getValue());</pre></td>
    </tr>
    <tr>
      <td class='line'>209</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>210</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>211</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l211s0' title='Executions: 2' class='covered'>if (fields != null</span> && <span id='l211s1' title='Executions: 0' class='uncovered'>fields.length > 0)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>212</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l212s0'>            ss.append("&fields=");</pre></td>
    </tr>
    <tr>
      <td class='line'>213</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l213s0'>            boolean first = true;</pre></td>
    </tr>
    <tr>
      <td class='line'>214</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l214s0' title='Executions: 0' class='uncovered'>for (String field</span> : <span id='l214s1' title='Executions: 0' class='uncovered'>fields)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>215</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>                <span id='l215s0' title='Executions: 0' class='uncovered'>if (!first)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>216</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l216s0'>                    ss.append(";");</pre></td>
    </tr>
    <tr>
      <td class='line'>217</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>                }</pre></td>
    </tr>
    <tr>
      <td class='line'>218</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l218s0'>                first = false;</pre></td>
    </tr>
    <tr>
      <td class='line'>219</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l219s0'>                ss.append(field);</pre></td>
    </tr>
    <tr>
      <td class='line'>220</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>221</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>222</td><td class='count'>2</td>
      <td><pre class='prettyprint jmp'>        <span id='l222s0' title='Executions: 2' class='covered'>if (isRangeValid)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>223</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l223s0'>            ss.append("&range=").append(start).append(":").append(count);</pre></td>
    </tr>
    <tr>
      <td class='line'>224</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>225</td><td class='count'>2</td>
      <td><pre class='prettyprint covered' id='l225s0'>        ss.append('}');</pre></td>
    </tr>
    <tr>
      <td class='line'>226</td><td class='count'>2</td>
      <td><pre class='prettyprint covered' id='l226s0'>        return ss.toString();</pre></td>
    </tr>
    <tr>
      <td class='line'>227</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>229</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    public boolean isJoinQueryOnly() {</pre></td>
    </tr>
    <tr>
      <td class='line'>230</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l230s0'>        return isJoinQueryOnly;</pre></td>
    </tr>
    <tr>
      <td class='line'>231</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>233</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    @Deprecated</pre></td>
    </tr>
    <tr>
      <td class='line'>234</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    public String toGetQuery() {</pre></td>
    </tr>
    <tr>
      <td class='line'>235</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l235s0' title='Executions: 0' class='uncovered'>if (keyLists == null</span> || <span id='l235s1' title='Executions: 0' class='uncovered'>keyLists.isEmpty())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>236</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l236s0'>            throw new IGraphClientException("toGetQuery failed with invalid AtomicQuery:[" + this + "]");</pre></td>
    </tr>
    <tr>
      <td class='line'>237</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>238</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l238s0'>        StringBuilder ss = new StringBuilder(128);</pre></td>
    </tr>
    <tr>
      <td class='line'>239</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l239s0'>        ss.append("table=").append(table);</pre></td>
    </tr>
    <tr>
      <td class='line'>240</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l240s0' title='Executions: 0' class='uncovered'>if (keyLists.size() == 1)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>241</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l241s0'>            KeyList keyList = keyLists.get(0);</pre></td>
    </tr>
    <tr>
      <td class='line'>242</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l242s0'>            ss.append("&pkey=").append(URLCodecUtil.encode(keyList.getPkey()));</pre></td>
    </tr>
    <tr>
      <td class='line'>243</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l243s0'>            String[] skeys = keyList.getSkeys();</pre></td>
    </tr>
    <tr>
      <td class='line'>244</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l244s0' title='Executions: 0' class='uncovered'>if (skeys != null</span> && <span id='l244s1' title='Executions: 0' class='uncovered'>skeys.length != 0)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>245</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l245s0'>                StringBuilder skeyBuilder = new StringBuilder(128);</pre></td>
    </tr>
    <tr>
      <td class='line'>246</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l246s0'>                skeyBuilder.append(skeys[0]);</pre></td>
    </tr>
    <tr>
      <td class='line'>247</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>                <span id='l247s0' title='Executions: 0' class='uncovered'>for (int i = 1</span>; i &lt; skeys.length; i++) {</pre></td>
    </tr>
    <tr>
      <td class='line'>248</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l248s0'>                    skeyBuilder.append(',').append(skeys[i]);</pre></td>
    </tr>
    <tr>
      <td class='line'>249</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>                }</pre></td>
    </tr>
    <tr>
      <td class='line'>250</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l250s0'>                String encodedSkey = URLCodecUtil.encode(skeyBuilder.toString());</pre></td>
    </tr>
    <tr>
      <td class='line'>251</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l251s0'>                ss.append("&skey=").append(encodedSkey);</pre></td>
    </tr>
    <tr>
      <td class='line'>252</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>253</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l253s0'>        } else {</pre></td>
    </tr>
    <tr>
      <td class='line'>254</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l254s0'>            StringBuilder pkeyBuilder = new StringBuilder(128);</pre></td>
    </tr>
    <tr>
      <td class='line'>255</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l255s0'>            pkeyBuilder.append(keyLists.get(0).getPkey());</pre></td>
    </tr>
    <tr>
      <td class='line'>256</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>            <span id='l256s0' title='Executions: 0' class='uncovered'>for (int i = 1</span>; i &lt; keyLists.size(); i++) {</pre></td>
    </tr>
    <tr>
      <td class='line'>257</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l257s0'>                pkeyBuilder.append(',').append(keyLists.get(i).getPkey());</pre></td>
    </tr>
    <tr>
      <td class='line'>258</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>            }</pre></td>
    </tr>
    <tr>
      <td class='line'>259</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l259s0'>            String encodedPkey = URLCodecUtil.encode(pkeyBuilder.toString());</pre></td>
    </tr>
    <tr>
      <td class='line'>260</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l260s0'>            ss.append("&pkey=").append(encodedPkey);</pre></td>
    </tr>
    <tr>
      <td class='line'>261</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>262</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l262s0'>        return ss.toString();</pre></td>
    </tr>
    <tr>
      <td class='line'>263</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr><td class='line'></td><td colspan='2'>&nbsp;</td></tr>
    <tr>
      <td class='line'>265</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    public String toFastQuery() {</pre></td>
    </tr>
    <tr>
      <td class='line'>266</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l266s0' title='Executions: 0' class='uncovered'>if (keyLists == null</span> || <span id='l266s1' title='Executions: 0' class='uncovered'>keyLists.isEmpty())</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>267</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l267s0'>            throw new IGraphClientException("toGetQuery failed with invalid AtomicQuery:[" + this + "]");</pre></td>
    </tr>
    <tr>
      <td class='line'>268</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>269</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l269s0'>        StringBuilder ss = new StringBuilder(128);</pre></td>
    </tr>
    <tr>
      <td class='line'>270</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l270s0'>        ss.append("table=").append(table);</pre></td>
    </tr>
    <tr>
      <td class='line'>271</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l271s0'>        ss.append("&keys=").append(URLCodecUtil.encode(keys));</pre></td>
    </tr>
    <tr>
      <td class='line'>272</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l272s0' title='Executions: 0' class='uncovered'>if (filter != null)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>273</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l273s0'>            ss.append("&filter=").append(URLCodecUtil.encode(filter));</pre></td>
    </tr>
    <tr>
      <td class='line'>274</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>275</td><td class='count'>0</td>
      <td><pre class='prettyprint jmp'>        <span id='l275s0' title='Executions: 0' class='uncovered'>if (isRangeValid)</span> {</pre></td>
    </tr>
    <tr>
      <td class='line'>276</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l276s0'>            ss.append("&range=").append(start).append(":").append(count);</pre></td>
    </tr>
    <tr>
      <td class='line'>277</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>        }</pre></td>
    </tr>
    <tr>
      <td class='line'>278</td><td class='count'>0</td>
      <td><pre class='prettyprint uncovered' id='l278s0'>        return ss.toString();</pre></td>
    </tr>
    <tr>
      <td class='line'>279</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>    }</pre></td>
    </tr>
    <tr>
      <td class='line'>280</td><td>&nbsp;</td>
      <td><pre class='prettyprint'>}</pre></td>
    </tr>
  </table>
</body>
</html>
